package schoolWork.work02;

public class Employee {
    private String name;
    private double salary;

    //构造方法
    public Employee(){};
    public Employee(String name,double salary){
        this.name = name;
        this.salary = salary;
    }

    public void setName(String name)
    {
        this.name = name;
    }

    public String getName()
    {
        return name;
    }

    public void setSalary(double salary)
    {
        this.salary = salary;
    }

    public double getSalary()
    {
        return salary;
    }

    public void raiseSalary(double byPercent)
    {
        salary = ( 1.0 + byPercent)*salary;
    }
}
